package pro.shushi.pamirs.ce.hr.core.action;

import org.springframework.stereotype.Component;
import pro.shushi.pamirs.meta.annotation.Action;
import pro.shushi.pamirs.meta.annotation.Model;
import pro.shushi.pamirs.meta.annotation.fun.extern.Slf4j;
import pro.shushi.pamirs.meta.api.session.PamirsSession;
import pro.shushi.pamirs.meta.enmu.ActionContextTypeEnum;
import pro.shushi.pamirs.meta.enmu.ViewTypeEnum;
import pro.shushi.pamirs.ce.hr.api.model.CustBusinessTrip;

@Slf4j
@Component
@Model.model(CustBusinessTrip.MODEL_MODEL)
public class CustBusinessTripAction {

    @Action(displayName = "sayHello", summary = "sayHello", bindingType = ViewTypeEnum.TABLE, contextType = ActionContextTypeEnum.SINGLE)
    public CustBusinessTrip sayHello(CustBusinessTrip trip){
        PamirsSession.getMessageHub().warn("定制版==>>Hello: " + trip.getBusinessReason());
        return trip;
    }
}
